<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script src="./src/react.js"></script>
    <script src="./src/react-dom.js"></script>
    <script src="./src/browser.js"></script>
</head>
<body>
    <div id="box"></div>
</body>
<script type="text/babel">
    // react中所有组件都要从React.component继承
    // react中组件名的首位必须大写
    class Aaa extends React.component{
        // react中认为所有组件都可以渲染到页面中，所以必须有render方法
        constructor(...args) {
            super(...args);
        }
        render() {
            return <span>aaa</span>
        }

    }
    let oDiv = document.getElementById('box');
    ReactDOM.render(
        <aaa></aaa>, oDiv
    );
</script>
</html>